]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
perf-tool: Fix default value for --extra-filter
authorYussuf Khalil <dev@pp3345.net>
Sun, 29 Apr 2018 16:03:40 +0000 (18:03 +0200)
committerFlorian Müllner <florian.muellner@gmail.com>
Sun, 29 Apr 2018 16:15:16 +0000 (16:15 +0000)
While it is theoretically fine to run --perf=hwtest without passing --hwtest,
the test will hang in this case because it fails to start gedit. Always append
Gedit to the default value for --extra-filter when running the "hwtest" test
to make it work fine without --hwtest.

src/gnome-shell-perf-tool.in

index b2a4521a34a5145d2360cbe1b4d7445ce7cac008..f4b48f73009d8f763e8a0e365741715dca53def4 100755 (executable)
@@ -347,10 +347,10 @@ if options.perf == None:
         options.perf = 'core'
 
 if options.extra_filter is None:
-    if options.hwtest:
-        options.extra_filter = ['Gedit']
-    else:
-        options.extra_filter = []
+    options.extra_filter = []
+
+if options.perf == 'hwtest':
+    options.extra_filter.append('Gedit')
 
 if args:
     parser.print_usage()